<extend name="public:base" />
<block name="breadcrumb">
    <ul class="breadcrumb">
        <li>
            <i class="ace-icon fa fa-book"></i>
            <a href="../User/index">{:L('应用管理')}</a>
        </li>
        <li class="">{:L('内容管理')}</li>
        <li class="active">{:L('单页管理')}</li>
    </ul>
</block>
<block name="c-block">
   <div class="page-content-area">

        <div class="row">
            <div class="col-xs-12">
                <!-- PAGE CONTENT BEGINS -->

                <div class="main-content">
                    <div class="row">
                        <div class="app-list app-100">
                            <div class="page-header">
                                <h1>
                                    单页管理
                                    <small>
                                        <i class="ace-icon fa fa-angle-double-right"></i>
                                        带(*)号为必填项目
                                    </small>
                                </h1>
                            </div>
                            <form class="form-horizontal" action="" method="post" role="form" id="card-info-form">
                                <input type="hidden" name="id" value="{$row['id']}">
                                <div class="row" align="">
                                    <div class="col-xs-12">

                                        <div class="form-group">
                                            <label class="col-sm-2 control-label no-padding-right" for="form-field-1"> * 标题 </label>

                                            <div class="col-sm-10">
                                                <input id="form-field-1" value="{$row['title']}" placeholder="标题" name="title" class="col-xs-10 col-sm-7" type="text">
                                            </div>
                                        </div>
                                        <div class="form-group">
                                            <label class="col-sm-2 control-label no-padding-right" for="form-field-1">详情 </label>

                                            <div class="col-sm-6">
                                                <textarea id="content_1" name="content" style="height:250px;">{$row['content']}</textarea>
                                            </div>
                                        </div>
                                        <div class="form-group">
                                            <label class="col-sm-2 control-label no-padding-right" for="form-field-1"> * 排序 </label>

                                            <div class="col-sm-10">
                                                <input id="sort" value="{$row['sort']}" placeholder="排序" name="sort" class="col-xs-1 col-sm-1" type="text">
                                            </div>
                                        </div>
                                        <div class="form-group">
                                            <label class="col-sm-2 control-label no-padding-right" for="form-field-1">是否用户中心显示 </label>
                                           <div class="col-sm-10 text-left">
                                                <label>
                                                    <input name="isuser" value="{$row['isuser']}" class="ace ace-switch ace-switch-3" type="checkbox">
                                                    <span class="lbl"></span>
                                                </label>
                                            </div>
                                        </div>
                                        <div class="form-group">
                                            <label class="col-sm-2 control-label no-padding-right" for="form-field-1">状态 </label>
                                           <div class="col-sm-10 text-left">
                                                <label>
                                                    <input name="status" value="{$row['status']}" class="ace ace-switch ace-switch-3" type="checkbox" checked="">
                                                    <span class="lbl"></span>
                                                </label>
                                            </div>
                                        </div>
                                        <div class="clearfix form-actions">
                                            <div class="form-group">
                                                <label class="col-sm-2 control-label no-padding-right"> &nbsp;</label>
                                                <div class="col-sm-10">
                                                    <button class="btn btn-info submit-ajax" type="button" data-form="#card-info-form">
                                                        <i class="ace-icon fa fa-check bigger-110"></i>
                                                        保存                                    </button>
                                                    &nbsp; &nbsp; &nbsp;
                                                    <button class="btn" type="button" onclick="history.back();">
                                                        <i class="ace-icon fa fa-undo bigger-110"></i>
                                                        取消                                    </button>

                                                </div>
                                            </div>
                                        </div>

                                    </div>
                                </div>
                            </form>
                        </div>
                    </div>
                </div>
                <!-- PAGE CONTENT BEGINS -->
            </div>
        </div>
    </div>
</block>

<block name="f-block">
<link rel="stylesheet" type="text/css"  href="__PLUGINS__/editor/themes/default/default.css"/>
<script src="__PLUGINS__/editor/kindeditor-min.js" type="text/javascript"></script>
<script type="text/javascript">

var editor;
KindEditor.ready(function(K) {
    editor = K.create('textarea[name="content"]', {
        resizeType : 1,
        allowPreviewEmoticons : false,
        allowImageUpload : false,
        items : [
            'fontname', 'fontsize', '|', 'forecolor', 'hilitecolor', 'bold', 'italic', 'underline',
            'removeformat', '|', 'justifyleft', 'justifycenter', 'justifyright', 'insertorderedlist',
            'insertunorderedlist', '|', 'emoticons', 'image', 'link'],
        afterCreate : function() {
          this.sync();
        },
        afterBlur:function() { this.sync(); }
    });
});

</script>
</block>